<?php /* Smarty version 2.6.26, created on 2014-10-03 21:13:04
         compiled from D:/wamp/www/wenda0910/Index/Tpl/Show/index.html */ ?>
<?php require_once(SMARTY_CORE_DIR . 'core.load_plugins.php');
smarty_core_load_plugins(array('plugins' => array(array('modifier', 'count', 'D:/wamp/www/wenda0910/Index/Tpl/Show/index.html', 77, false),array('modifier', 'date_format', 'D:/wamp/www/wenda0910/Index/Tpl/Show/index.html', 88, false),)), $this); ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en">
<head>
	<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
	<title>问答系统</title>
	<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => '../common/head.html', 'smarty_include_vars' => array()));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>
	<link rel="stylesheet" href="<?php echo @__PUBLIC__; ?>
/Css/question.css" />
	<script type="text/javascript" src="<?php echo @__PUBLIC__; ?>
/Js/question.js"></script>
	<div id='location'>
	
		<a href="<?php echo @__ROOT__; ?>
?c=list&cid=0">全部分类</a>
		<?php unset($this->_sections['n']);
$this->_sections['n']['loop'] = is_array($_loop=$this->_tpl_vars['father_cate']) ? count($_loop) : max(0, (int)$_loop); unset($_loop);
$this->_sections['n']['name'] = 'n';
$this->_sections['n']['show'] = true;
$this->_sections['n']['max'] = $this->_sections['n']['loop'];
$this->_sections['n']['step'] = 1;
$this->_sections['n']['start'] = $this->_sections['n']['step'] > 0 ? 0 : $this->_sections['n']['loop']-1;
if ($this->_sections['n']['show']) {
    $this->_sections['n']['total'] = $this->_sections['n']['loop'];
    if ($this->_sections['n']['total'] == 0)
        $this->_sections['n']['show'] = false;
} else
    $this->_sections['n']['total'] = 0;
if ($this->_sections['n']['show']):

            for ($this->_sections['n']['index'] = $this->_sections['n']['start'], $this->_sections['n']['iteration'] = 1;
                 $this->_sections['n']['iteration'] <= $this->_sections['n']['total'];
                 $this->_sections['n']['index'] += $this->_sections['n']['step'], $this->_sections['n']['iteration']++):
$this->_sections['n']['rownum'] = $this->_sections['n']['iteration'];
$this->_sections['n']['index_prev'] = $this->_sections['n']['index'] - $this->_sections['n']['step'];
$this->_sections['n']['index_next'] = $this->_sections['n']['index'] + $this->_sections['n']['step'];
$this->_sections['n']['first']      = ($this->_sections['n']['iteration'] == 1);
$this->_sections['n']['last']       = ($this->_sections['n']['iteration'] == $this->_sections['n']['total']);
?>
		<?php if ($this->_sections['n']['last']): ?>
			&gt;&nbsp;<?php echo $this->_tpl_vars['father_cate'][$this->_sections['n']['index']]['title']; ?>
&nbsp;&nbsp;
			<?php else: ?>
			&gt;&nbsp;<a href="<?php echo @__ROOT__; ?>
?c=list&cid=<?php echo $this->_tpl_vars['father_cate'][$this->_sections['n']['index']]['cid']; ?>
"><?php echo $this->_tpl_vars['father_cate'][$this->_sections['n']['index']]['title']; ?>
</a>&nbsp;&nbsp;
			<?php endif; ?>
		<?php endfor; endif; ?>	
	</div>

<!--------------------中部-------------------->
	<div id='center-wrap'>
		<div id='center'>
			<div id='left'>
				<div id='answer-info'>
					<!-- 如果没有解决用wait -->
					<?php if ($this->_tpl_vars['data']['solve'] == 0): ?>
					<div class='ans-state wait'></div>
					<?php else: ?>
					<div class='ans-state '></div>
					<?php endif; ?>
					<div class='answer'>
						<p class='ans-title'><?php echo $this->_tpl_vars['data']['content']; ?>

							<b class='point'><?php echo $this->_tpl_vars['data']['reward']; ?>
</b>
						</p>
					</div>
					<ul>
						<li><a href=""><?php echo $this->_tpl_vars['data']['username']; ?>
</a></li>
						<li><i class="level lv<?php echo $this->_tpl_vars['data']['level']; ?>
" title="level lv<?php echo $this->_tpl_vars['data']['level']; ?>
"></i></li>
						<li><?php echo $this->_tpl_vars['data']['time']; ?>
</li>
				
					</ul>
					<?php if ($_SESSION['user'] != null && $_SESSION['uid'] != null && $this->_tpl_vars['data']['solve'] == 0 && $_SESSION['user'] != $this->_tpl_vars['data']['username']): ?>
					<div class='ianswer'>
						<form action="<?php echo @__ROOT__; ?>
?c=show&m=answer" method='POST'>
							<p>我来回答</p>
							<textarea name="content"></textarea>
							<input type="hidden" name='asid' value="<?php echo $this->_tpl_vars['data']['asid']; ?>
">
							<input type="submit" value='提交回答' id='anw-sub'/>
						</form>
					</div>

					<?php else: ?>
					<?php endif; ?>
					<?php if ($this->_tpl_vars['data']['solve'] == 1): ?>
					<!-- 满意回答 -->
					<div class='ans-right'>
						<p class='title'><i></i>满意回答<span></span></p>
						<p class='ans-cons'><?php echo $this->_tpl_vars['best']['content']; ?>
</p>
						<dl>
							<dt>
								<a href=""><img src="<?php echo $this->_tpl_vars['best']['face']; ?>
" width='48' height='48'/></a>
							</dt>
							<dd>
								<a href=""><?php echo $this->_tpl_vars['best']['username']; ?>
</a>
							</dd>
							<dd><i class='level lv<?php echo $this->_tpl_vars['best']['level']; ?>
'></i></dd>
							<dd><?php echo $this->_tpl_vars['best']['ratio']; ?>
%</dd>
						</dl>
					</div>
					<?php else: ?>
					<?php endif; ?>
				</div>

				<div id='all-answer'>
					<div class='ans-icon'></div>
					<p class='title'>共 <strong><?php echo count($this->_tpl_vars['answer']); ?>
</strong> 条回答</p>
					<ul>
					<?php $_from = $this->_tpl_vars['answer']; if (!is_array($_from) && !is_object($_from)) { settype($_from, 'array'); }if (count($_from)):
    foreach ($_from as $this->_tpl_vars['k'] => $this->_tpl_vars['v']):
?>
						<li>
							<div class='face'>
								<a href="">
									<img src="<?php echo $this->_tpl_vars['v']['face']; ?>
" width='48' height='48'/>
								<?php echo $this->_tpl_vars['v']['username']; ?>

								</a>
							</div>
							<div class='cons blue'>
								<p><?php echo $this->_tpl_vars['v']['content']; ?>
<span style='color:#888;font-size:12px'>&nbsp;&nbsp;<?php echo ((is_array($_tmp=$this->_tpl_vars['v']['time'])) ? $this->_run_mod_handler('date_format', true, $_tmp, "%y-%m-%d") : smarty_modifier_date_format($_tmp, "%y-%m-%d")); ?>
</span></p>
							</div>
								<?php if ($this->_tpl_vars['data']['solve'] == 0 && $_SESSION['user'] == $this->_tpl_vars['data']['username']): ?>
								<a href="<?php echo @__ROOT__; ?>
?c=show&m=accept&anid=<?php echo $this->_tpl_vars['v']['anid']; ?>
" class='adopt-btn'>采纳</a>
								<?php else: ?>
								<?php endif; ?>
							
						</li>
						<?php endforeach; endif; unset($_from); ?>

						<!-- <li>
							<div class='face'>
								<a href="">
									<img src="<?php echo @__PUBLIC__; ?>
/Images/noface.gif" width='48' height='48'/>
								</a>
							</div>
							<div class='cons blue'>
								<p>真不错啊！<span style='color:#888;font-size:12px'>&nbsp;&nbsp;(1900.1.1)</span></p>
							</div>
							
								<a href="" class='adopt-btn'>采纳</a>
							
						</li> -->
					</ul>
					<div class='page'>
						<a href="">1</a>
						<a href="">2</a>
						<a href="">3</a>
						<a href="">4</a>
					</div>
				</div>
				<div id='other-ask'>
					<p class='title'>待解决的相关问题</p>
					<table>
					<?php unset($this->_sections['m']);
$this->_sections['m']['loop'] = is_array($_loop=$this->_tpl_vars['nosolve']) ? count($_loop) : max(0, (int)$_loop); unset($_loop);
$this->_sections['m']['name'] = 'm';
$this->_sections['m']['show'] = true;
$this->_sections['m']['max'] = $this->_sections['m']['loop'];
$this->_sections['m']['step'] = 1;
$this->_sections['m']['start'] = $this->_sections['m']['step'] > 0 ? 0 : $this->_sections['m']['loop']-1;
if ($this->_sections['m']['show']) {
    $this->_sections['m']['total'] = $this->_sections['m']['loop'];
    if ($this->_sections['m']['total'] == 0)
        $this->_sections['m']['show'] = false;
} else
    $this->_sections['m']['total'] = 0;
if ($this->_sections['m']['show']):

            for ($this->_sections['m']['index'] = $this->_sections['m']['start'], $this->_sections['m']['iteration'] = 1;
                 $this->_sections['m']['iteration'] <= $this->_sections['m']['total'];
                 $this->_sections['m']['index'] += $this->_sections['m']['step'], $this->_sections['m']['iteration']++):
$this->_sections['m']['rownum'] = $this->_sections['m']['iteration'];
$this->_sections['m']['index_prev'] = $this->_sections['m']['index'] - $this->_sections['m']['step'];
$this->_sections['m']['index_next'] = $this->_sections['m']['index'] + $this->_sections['m']['step'];
$this->_sections['m']['first']      = ($this->_sections['m']['iteration'] == 1);
$this->_sections['m']['last']       = ($this->_sections['m']['iteration'] == $this->_sections['m']['total']);
?>
						<tr>
						
							<td class='t1'><a href="<?php echo @__ROOT__; ?>
?c=show&asid=<?php echo $this->_tpl_vars['nosolve'][$this->_sections['m']['index']]['asid']; ?>
"><?php echo $this->_tpl_vars['nosolve'][$this->_sections['m']['index']]['content']; ?>
</a></td>
							<td><?php echo $this->_tpl_vars['nosolve'][$this->_sections['m']['index']]['answer']; ?>
&nbsp;回答</td>
							<td><?php echo $this->_tpl_vars['nosolve'][$this->_sections['m']['index']]['time']; ?>
</td>
						</tr>
						<?php endfor; endif; ?>
					</table>
				</div>
			</div>
		<!-- 右侧 -->
		<?php $_smarty_tpl_vars = $this->_tpl_vars;
$this->_smarty_include(array('smarty_include_tpl_file' => '../common/right.html', 'smarty_include_vars' => array()));
$this->_tpl_vars = $_smarty_tpl_vars;
unset($_smarty_tpl_vars);
 ?>
<!-- ---右侧结束---- -->
			
		</div>

	</div>
	
<!--------------------中部结束-------------------->

<!-- 底部 -->
	<div id='bottom'>
		<p>Copyright © 2013 Qihoo.Com All Rights Reserved 廖东廷</p>
		<p>京公安网备xxxxxxxxxxxx</p>
	</div>
<!--[if IE 6]>
    <script type="text/javascript" src="<?php echo @__PUBLIC__; ?>
/Js/iepng.js"></script>
    <script type="text/javascript">
    	DD_belatedPNG.fix('.logo','background');
        DD_belatedPNG.fix('.nav-sel a','background');
        DD_belatedPNG.fix('.ask-cate i','background');
    </script>
<![endif]-->
</body>
</html>
<!-- 底部结束 -->